package service;

import entity.Book;
import entity.Borrow;

import java.sql.SQLException;
import java.util.List;

public interface BookService {
    public List<Book> findAll(int page) throws SQLException;
    public int getPages() throws SQLException;
    public int getBorrowPages(Integer readerId) throws SQLException;
    public void addBorrow(Integer bookid,Integer readerid) throws SQLException;
    public List<Borrow> findAllBorrowByReaderId(Integer id,Integer page) throws SQLException;
    public List<Borrow> findAllBorrowByState(Integer state,Integer page) throws SQLException;
    public int getBorrowPagesByState(Integer state) throws SQLException;
    public void handleBorrow(Integer borrowId,Integer state,Integer adminId) throws SQLException;
}
